<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
    <script src="./js/jquery.js"></script>
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"
        integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu" crossorigin="anonymous">

    <!-- 可选的 Bootstrap 主题文件（一般不用引入） -->
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap-theme.min.css"
        integrity="sha384-6pzBo3FDv/PJ8r2KRkGHifhEocL+1X2rVCTTkUfGk7/0pbek5mMa1upzvWbrUbOZ" crossorigin="anonymous">

    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
    <script src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"
        integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd"
        crossorigin="anonymous"></script>
    <link rel="stylesheet" href="https://unpkg.com/bootstrap-table@1.20.2/dist/bootstrap-table.min.css">
    <script src="https://unpkg.com/bootstrap-table@1.20.2/dist/bootstrap-table.min.js"></script>

    <style>
        * {
            padding: 5px;

        }

        .a h3 {

            display: inline-block;

        }
    </style>
</head>

<body>


    <div class="a" style="background-color: rgb(61, 221, 221);">
        <h3 style="color:rgb(255, 0, 0)">&#9774 当前订单状态：待付款</h3>
        <form class="navbar-form navbar-right">
            <a id="close" href="./salecontrol.html"><button type="button" class=" btn-default-gbdd">关闭订单</button></a>
            <button type="submit" class=" btn-default-bzdd" onclick="ck();">备注订单</button>
        </form>
    </div>



    <div id="4" style="background-color: aqua;">&#9993基本信息</div>

    <table id="table1"></table>

    <div style="background-color: aqua;">&#9993收货人信息</div>

    <table id="table2"></table>

    <div style="background-color: aqua;">&#9993商品信息</div>

    <table id="table3"></table>

    <div style="background-color: aqua;">&#9993费用信息</div>

    <table id="table4"></table>
</body>
<script>
    var ck = function () {
        var x = prompt("请输入备注内容: ", "顺丰快递");/*第一个变量为提示语，第二个变量为默认初始值*/
        alert(x);
    }

    
    $(  
        
        $('#table1').bootstrapTable({
            url: "http://192.168.96.193:8033/order/selectbyorderid?orderId=" + localStorage["name"],
            

            columns: [{
                field: 'orderId',
                title: '订单编号'
            }, {
                field: 'wldhDate',
                title: '物流单号'
            }, {
                field: 'userId',
                title: '用户账号'
            }, {
                field: 'zffsDate',
                title: '支付方式'
            }, {
                field: 'time',
                title: '订单时间'
            }, {
                field: 'ddlxDate',
                title: '订单类型'
            }],
            
        })

    )
    $(
        $('#table2').bootstrapTable({
            url: "http://192.168.96.193:8033/order/selectbyorderid?orderId=" + localStorage["name"],


            columns: [{
                field: 'userName',
                title: '收货人'
            }, {
                field: 'sjhmDate',
                title: '手机号码'
            }, {
                field: 'yzbmDate',
                title: '邮政编码'
            }, {
                field: 'shdzDate',
                title: '收货地址'
            }],
            data: []
        })

    )
    $(
        $('#table3').bootstrapTable({
            url: "http://192.168.96.193:8033/order/selectbyorderid?orderId=" + localStorage["name"],


            columns: [{
                field: 'sptpDate',
                title: '商品图片'
            }, {
                field: 'spmcDate',
                title: '商品名称'
            }, {
                field: 'orderprice',
                title: '价格'
            }, {
                field: 'slDate',
                title: '数量'
            }, {
                field: 'orderprice',
                title: '小计'
            }],
            data: []
        })

    )
    $(
        $('#table4').bootstrapTable({
            url: "http://192.168.96.193:8033/order/selectbyorderid?orderId=" + localStorage["name"],


            columns: [{
                field: 'orderprice',
                title: '商品合计'
            }, {
                field: 'yfDate',
                title: '运费'
            }, {
                field: 'orderprice',
                title: '订单总金额'
            }, {
                field: 'orderprice',
                title: '应付款金额'
            }],
            data: []
        })

    )
    function close(params) {
        console.log("555")
        //window.location.href = './salecontrol.html';
    }
    $(() => {
        $("#close").click((e) => {
            parent.tablechange(e)
        })
    })
</script>

</html>